<?php class Mod_ville extends CI_Model {
	
	function __construct()
	    {
		parent::__construct();
            }
            function getNomVilleId($id_ville) {
                $sql="SELECT nom_ville FROM ville WHERE id_ville='$id_ville'"; 
                $Q = $this->db->query($sql);
                if ($Q->num_rows()>0){
			foreach ($Q->result_array() as $row){
                                $nom_ville = $row['nom_ville'];
			}		 
                }
                $Q->free_result();
                return $nom_ville;
            }
}